<!DOCTYPE html>
<html lang="zh_CN">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

</body>
<script src="https://cdn.bootcdn.net/ajax/libs/lodash.js/4.17.21/lodash.js"></script>
<script type="text/javascript">
    var a = [1, 2, 3];

    var b = _.cloneDeep(a); // cloneDeep 是 lodash 提供的

    b.push(4);

    console.log(b, a);


</script>

</html>
